/*
 * Class: SubsidiaryAdapter
 * Created by: Mary Joy Pascual
 * Date Created: 06/16/2014
 * Company: Netsuite
*/
package com.netsuite.adapter;

import com.netsuite.logger.LoggerImp;
import com.netsuite.pojo.SubsidiaryPOJO;
import com.netsuite.webservices.lists.accounting_2014_1.Subsidiary;

public class SubsidiaryAdapter {
	
	private static String CLASS_NAME = SubsidiaryAdapter.class.getName();

	public static SubsidiaryPOJO setSubsidiary (Subsidiary sub){
		
		LoggerImp.startLog(CLASS_NAME, "setSubsidiary() - Subsidiary to SubsidiaryPOJO");
		
		SubsidiaryPOJO subPojo = new SubsidiaryPOJO();
		subPojo.setSubsidiaryId(sub.getInternalId());
		subPojo.setSubsidiaryName(sub.getName());
		
		LoggerImp.endLog(CLASS_NAME, "setSubsidiary() - Subsidiary to SubsidiaryPOJO");
		
		return subPojo;
	}
}
